<template>
  <div class="home">
    <img alt="Vue logo" src="../assets/logo.png" />
    <HelloWorld msg="Welcome to Your Vue.js App" />
    <button @click="handleModle('toggle')">dark-mode:toggle</button>
    <button @click="handleModle('system')">dark-mode:system</button>
  </div>
</template>

<script>
// @ is an alias to /src
import HelloWorld from "@/components/HelloWorld.vue";
export default {
  name: "Home",
  components: {
    HelloWorld,
  },
  async mounted() {

  },
  methods: {
    handleModle(type) {
      window.darkMode[type]();
      // window.darkMode[type]
    },
  },
};
</script>
